package cn.ichensw.otherworldlystationbackend.service;

import cn.ichensw.otherworldlystationbackend.model.dto.bangumi.BangumiSearchRequest;
import cn.ichensw.otherworldlystationbackend.model.dto.bangumi.BangumiSearchV0Request;
import cn.ichensw.otherworldlystationbackend.model.vo.bangumi.BangumiCalendarVO;
import cn.ichensw.otherworldlystationbackend.model.vo.bangumi.BangumiSearchSubjectSmallVO;
import cn.ichensw.otherworldlystationbackend.model.vo.bangumi.BangumiSubjectDetailVO;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;

import javax.servlet.http.HttpServletRequest;
import java.util.List;

/**
 * Bangumi接口Service
 *
 * @author csw
 */
public interface BangumiService {


    /**
     * 根据关键字搜索条目(动漫)
     *
     * @param request            请求参数
     * @param httpServletRequest
     * @return 条目列表
     */
    Page<BangumiSearchSubjectSmallVO> searchSubject(BangumiSearchRequest request, HttpServletRequest httpServletRequest);

    /**
     * 搜索条目(复杂搜索)试验性API 随时可能失效
     *
     * @param request            请求参数
     * @param httpServletRequest
     * @return 条目列表
     */
    Page<BangumiSearchSubjectSmallVO> searchSubjectV0(BangumiSearchV0Request request, HttpServletRequest httpServletRequest);

    /**
     * 每日放送
     *
     * @return 条目列表
     */
    List<BangumiCalendarVO> calendar();

    /**
     * 根据ID获取条目信息
     *
     * @param subjectId 条目id
     * @param request
     * @return 条目详情
     */
    BangumiSubjectDetailVO subjectsDetail(Integer subjectId, HttpServletRequest request);
}
